package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

/**
 * 商品实体类
 */
@TableName("t_product")
public class ProductBean {
    //    商品编号
    @TableId(value = "pk_productId", type = IdType.AUTO)
    private String id;

    //    商品名称
    @TableField("p_name")
    private String name;

    //    商品品牌
    @TableField("p_brand")
    private String brand;

    //    商品类型
    @TableField("p_type")
    private String type;

    //    商品数量
    @TableField("p_num")
    private Integer num;

    //    商品图片路径
    @TableField("p_imgPath")
    private String imgPath;

    //    采购价
    @TableField("p_buyMoney")
    private Integer buyMoney;

    //    销售价
    @TableField("p_sellMoney")
    private Integer sellMoney;

    public ProductBean() {
    }

    public ProductBean(String name, String brand, String type,
                       Integer num, String imgPath, Integer buyMoney, Integer sellMoney) {
        this.name = name;
        this.brand = brand;
        this.type = type;
        this.num = num;
        this.imgPath = imgPath;
        this.buyMoney = buyMoney;
        this.sellMoney = sellMoney;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getBrand() {
        return brand;
    }

    public void setBrand(String brand) {
        this.brand = brand;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public Integer getNum() {
        return num;
    }

    public void setNum(Integer num) {
        this.num = num;
    }

    public String getImgPath() {
        return imgPath;
    }

    public void setImgPath(String imgPath) {
        this.imgPath = imgPath;
    }

    public Integer getBuyMoney() {
        return buyMoney;
    }

    public void setBuyMoney(Integer buyMoney) {
        this.buyMoney = buyMoney;
    }

    public Integer getSellMoney() {
        return sellMoney;
    }

    public void setSellMoney(Integer sellMoney) {
        this.sellMoney = sellMoney;
    }

    @Override
    public String toString() {
        return "ProductBean{" +
                "id='" + id + '\'' +
                ", name='" + name + '\'' +
                ", brand='" + brand + '\'' +
                ", type='" + type + '\'' +
                ", num=" + num +
                ", imgPath='" + imgPath + '\'' +
                ", buyMoney=" + buyMoney +
                ", sellMoney=" + sellMoney +
                '}';
    }
}
